package com.youzheng.entity;

public class Product {
    private Integer pid;
    private String pname;
    private Double price;
    private Integer num;
    private String desc;
    private Integer tid;
    private Type type;
    private Integer uid;
    private User user;

    public Integer getUid() {
        return uid;
    }

    public void setUid(Integer uid) {
        this.uid = uid;
    }

    public User getUser() {
        return user;
    }

    public void setUser(User user) {
        this.user = user;
    }

    public Product() {
    }

    public Product(Integer pid, String pname, Double price, Integer num, String desc, Integer tid, Type type) {
        this.pid = pid;
        this.pname = pname;
        this.price = price;
        this.num = num;
        this.desc = desc;
        this.tid = tid;
        this.type = type;
    }

    public Type getType() {
        return type;
    }

    public void setType(Type type) {
        this.type = type;
    }

    public Product(Integer pid, String pname, Double price, Integer num, String desc, Integer tid) {
        this.pid = pid;
        this.pname = pname;
        this.price = price;
        this.num = num;
        this.desc = desc;
        this.tid = tid;
    }

    @Override
    public String toString() {
        return "Product{" +
                "pid=" + pid +
                ", pname='" + pname + '\'' +
                ", price=" + price +
                ", num=" + num +
                ", desc='" + desc + '\'' +
                ", tid=" + tid +
                '}';
    }

    public Integer getPid() {
        return pid;
    }

    public void setPid(Integer pid) {
        this.pid = pid;
    }

    public String getPname() {
        return pname;
    }

    public void setPname(String pname) {
        this.pname = pname;
    }

    public Double getPrice() {
        return price;
    }

    public void setPrice(Double price) {
        this.price = price;
    }

    public Integer getNum() {
        return num;
    }

    public void setNum(Integer num) {
        this.num = num;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public Integer getTid() {
        return tid;
    }

    public void setTid(Integer tid) {
        this.tid = tid;
    }
}
